<!DOCTYPE html>
<html><head>
        <meta charset="utf-8">
    <title>童老师ThinkPHP交流群：484519446</title>

    <meta name="description" content="Dashboard">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <!--Basic Styles-->
    <link href="__admin__/style/bootstrap.css" rel="stylesheet">
    <link href="__admin__/style/font-awesome.css" rel="stylesheet">
    <link href="__admin__/style/weather-icons.css" rel="stylesheet">

    <!--Beyond styles-->
    <link id="beyond-link" href="__admin__/style/beyond.css" rel="stylesheet" type="text/css">
    <link href="__admin__/style/demo.css" rel="stylesheet">
    <link href="__admin__/style/typicons.css" rel="stylesheet">
    <link href="__admin__/style/animate.css" rel="stylesheet">
    
</head>
<body>
    <!-- 头部 -->
    {include file="common/top"}
    <!-- /头部 -->
    
    <div class="main-container container-fluid">
        <div class="page-container">
            <!-- Page Sidebar -->
            {include file="common/left"}
            <!-- /Page Sidebar -->
            <!-- Page Content -->
            <div class="page-content">
                <!-- Page Breadcrumb -->
                <div class="page-breadcrumbs">
                    <ul class="breadcrumb">
                        <li>
                            <a href="#">系统</a>
                        </li>
                        <li>
                            <a href="#">文章管理</a>
                        </li>
                        <li class="active">添加文章</li>
                    </ul>
                </div>
                <!-- /Page Breadcrumb -->

                <!-- Page Body -->
                <div class="page-body">
                    
<div class="row">
    <div class="col-lg-12 col-sm-12 col-xs-12">
        <div class="widget">
            <form class="form-horizontal" action="" method="post" enctype="multipart/form-data">
                <div class="widget-body">
                    <div class="widget-main ">
                        <div class="tabbable">
                            <ul class="nav nav-tabs tabs-flat" id="myTab11">
                                <li class="active">
                                    <a data-toggle="tab" href="#home11">
                                        店铺配置
                                    </a>
                                </li>
                                <li class="">
                                    <a data-toggle="tab" href="#profile11">
                                        商品配置
                                    </a>
                                </li>
                            </ul>
                            <div class="tab-content tabs-flat">
                                <div id="home11" class="tab-pane active">
                                    
                                        <?php foreach($shopConfRes as $k=>$v): ?>
                                        <div class="form-group">
                                            <label for="username" class="col-sm-2 control-label no-padding-right">{$v['cname']}</label>
                                            <div class="col-sm-6">
                                                <!-- 文本 -->
                                                <?php if($v['form_type'] == 'text'): ?>
                                                <input class="form-control" placeholder="" name="{$v['ename']}" type="text" value="{$v['value']}">
                                                <!-- 单选框 -->
                                                <?php elseif($v['form_type'] == 'radio'): ?>
                                                    <?php if($v['values']):
                                                        $radioarr = explode(',',$v['values']);
                                                        foreach($radioarr as $k1 => $v1):
                                                    ?>
                                                    <div class="radio" style="float:left;margin-left:15px;">
                                                        <label>
                                                            <input name="{$v['ename']}" {if condition='$v1 eq $v["value"]'} checked="checked" {/if} type="radio" class="colored-blue" value='{$v1}'>
                                                            <span class="text"><?php echo $v1; ?></span>
                                                        </label>
                                                    </div>
                                                    <?php endforeach;endif; ?>
                                                <!-- 多选框 -->
                                                <?php elseif($v['form_type'] == 'checkbox'): ?>
                                                    <?php if($v['values']):
                                                        $boxarr = explode(',',$v['values']);
                                                        $checkboxarr = explode(',',$v['value']);
                                                        foreach($boxarr as $k2 => $v2):
                                                    ?>
                                                <div class="checkbox" style="float:left;margin-left:15px;">
                                                    <label>
                                                        <input type="checkbox" class="colored-blue" name="{$v['ename']}[]" value="{$v2}" <?php if(in_array($v2,$checkboxarr)){ echo "checked='checked'";} ?> >
                                                        <span class="text"><?php echo $v2; ?></span>
                                                    </label>
                                                </div>
                                                    <?php endforeach;endif; ?>
                                                <!-- 上传文件 -->
                                                <?php elseif($v['form_type'] == 'file'): ?>
                                                <input type="file" name="{$v['ename']}" id="">
                                                <img src="__upload__/{$v['value']}" alt="">
                                                <!-- 文本域 -->
                                                <?php elseif($v['form_type'] == 'textarea'): ?>
                                                <textarea name="{$v['ename']}" class='form-control'>{$v['value']}</textarea>
                                                <!-- 下拉菜单 -->
                                                <?php elseif($v['form_type'] == 'select'): ?>
                                                <select name="{$v['ename']}" id="" class="form-control">
                                                    <?php if($v['values']):
                                                        $boxarr = explode(',',$v['values']);
                                                        foreach($boxarr as $k3 => $v3):
                                                    ?>
                                                    <option {if condition='$v3 eq $v["value"]'} selected="selected" {/if} value="{$v3}"><?php echo $v3; ?></option>
                                                    <?php endforeach;endif; ?>
                                                </select>
                                                <?php endif; ?>
                                            </div>
                                            <!-- <p class="help-block col-sm-4 red">* 必填</p> -->
                                        </div>
                                        <?php endforeach; ?>
                                    
                                </div>

                                <div id="profile11" class="tab-pane">
                                    <p>Food truck fixie locavore, accusamus mcsweeney's marfa nulla single-origin coffee squid.</p>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <div class="col-sm-offset-2 col-sm-10">
                                <button type="submit" class="btn btn-default">保存信息</button>
                            </div>
                        </div>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>

                </div>
                <!-- /Page Body -->
            </div>
            <!-- /Page Content -->
        </div>  
    </div>

        <!--Basic Scripts-->
    <script src="__admin__/style/jquery_002.js"></script>
    <script src="__admin__/style/bootstrap.js"></script>
    <script src="__admin__/style/jquery.js"></script>
    <!--Beyond Scripts-->
    <script src="__admin__/style/beyond.js"></script>
    


</body></html>